.TH std::experimental::make_optional 3 "2024.06.10" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
std::experimental::make_optional \- std::experimental::make_optional

.SH Synopsis
   Defined in header <experimental/optional>
   template< class T >

   constexpr optional<typename std::decay<T>::type>  (library fundamentals TS)

       make_optional( T&& value );

   Creates an optional object from value. Effectively calls optional<typename
   std::decay<T>::type>(std::forward<T>(value)).

.SH Parameters

   value - the value to construct optional object with

.SH Return value

   An optional object with value as the contained value.

.SH Exceptions

   Throws any exception thrown by the constructor of T.

.SH See also

   constructor   constructs the optional object
                 \fI(public member function)\fP

.SH Category:
     * Noindexed pages
